<template>
  <div >
    <!-- <Stock v-if="$store.state.status == 0" /> -->
    <SellerWorkbench v-if="userInfo != null && userInfo.identity == 1 "/>
    <RetailersStatistical v-if="userInfo != null && userInfo.identity == 0 " />
  </div>
</template>
<script>
import Stock from "../userpages/nologin/Stock";
import RetailersStatistical from "../userpages/retailers/RetailersStatistical";
import SellerWorkbench from "../userpages/seller/SellerWorkbench";
export default {
  components: {
    Stock,
    RetailersStatistical,
    SellerWorkbench,
  },
  computed: {
    userInfo() {
      return this.$store.getters.getUserInfo;
    },
  },
  mounted() {
    this.$store.commit("setNavStatus", 1);
  },
  destroyed(){
    this.$store.commit("init");
  },
  
};
</script>